﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Admin.Master" AutoEventWireup="true" CodeBehind="TimesheetReportChart.aspx.cs" Inherits="Presentation.Reporting.TimeSheetReport" %>
<%@ Register assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" namespace="Microsoft.Reporting.WebForms" tagprefix="rsweb" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">
        .style1
        {
            width: 5%;
            height: 40px;
        }
        .style2
        {
            width: 30%;
            height: 40px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <asp:ScriptManager ID="scriptManager" runat="server">
    </asp:ScriptManager>
    <table border="0" cellpadding="0" cellspacing="0" id="content-table" width="100%">
        <tr>
            <th rowspan="4" class="sized">
                <img src="/Content/images/shared/side_shadowleft.jpg" width="20" height="300" alt="" />
            </th>
            <th class="topleft">
            </th>
            <td id="tbl-border-top">
            </td>
            <th class="topright">
            </th>
            <th rowspan="4" class="sized">
                <img src="/Content/images/shared/side_shadowright.jpg" width="20" height="300" alt="" />
            </th>
        </tr>
        <tr>
            <td id="tbl-border-left">
            </td>
            <td>
                <!--  start content-table-inner -->
                <div id="content-table-inner">
                    <table border="0" cellpadding="0" cellspacing="0" width="100%">
                        <tr valign="top">
                            <td>
                                <!-- start id-form -->
                                <table border="0" width="100%" cellspacing="0" cellpadding="0" border="0" id="id-form">
                                    <tr>
                                        <td colspan="2" style="width: 35%">
                                            <div class="legend-text">
                                                Data information
                                            </div>
                                            <div class="hrStyle">
                                                <hr />
                                            </div>
                                        </td>
                                        <td style="width: 65%">
                                            <div class="legend-text">
                                                Chart information
                                            </div>
                                            <div class="hrStyle">
                                                <hr />
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <th class="style1">
                                        </th>
                                        <td class="style2">
                                            <asp:RequiredFieldValidator ID="StartDateRequiredFieldValidator"  Display="Dynamic"
                                                runat="server" ControlToValidate="StartdateTextBox" CssClass="validation-msg" 
                                                ErrorMessage="Start date is not empty !" ForeColor="Red"></asp:RequiredFieldValidator>
                                            <asp:RegularExpressionValidator ID="StartDateRegularExpressionValidator" runat="server" 
                                                ErrorMessage="Start date is invaid !" ForeColor="Red" ControlToValidate="StartdateTextBox"  Display="Dynamic"
                                                ValidationExpression="^(((0?[1-9]|1[012])/(0?[1-9]|1\d|2[0-8])|(0?[13456789]|1[012])/(29|30)|(0?[13578]|1[02])/31)/(19|[2-9]\d)\d{2}|0?2/29/((19|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(([2468][048]|[3579][26])00)))$" 
                                                CssClass="validation-msg"></asp:RegularExpressionValidator>
                                        </td>
                                        <td rowspan="5" valign="top">
                                            <rsweb:ReportViewer ID="TimeSheetReportViewer" runat="server" 
                                                Font-Names="Verdana" Font-Size="8pt" InteractiveDeviceInfos="(Collection)" 
                                                ShowToolBar="False" WaitMessageFont-Names="Verdana" WaitMessageFont-Size="14pt">
                                                <LocalReport ReportPath="Reporting\TimesheetReportChart.rdlc">
                                                    <DataSources>
                                                        <rsweb:ReportDataSource DataSourceId="odsStatusName" Name="DataSet1" />
                                                    </DataSources>
                                                </LocalReport>
                                            </rsweb:ReportViewer>
                                            <asp:ObjectDataSource ID="odsStatusName" runat="server" 
                                                OldValuesParameterFormatString="original_{0}" SelectMethod="GetData" 
                                                
                                                TypeName="Presentation.TimesheetRoportChartTableAdapters.TimesheetStatusTableAdapter">
                                                <SelectParameters>
                                                    <asp:ControlParameter ControlID="StartdateTextBox" DefaultValue="1/1/2012" 
                                                        Name="FromDate" PropertyName="Text" Type="DateTime" />
                                                    <asp:ControlParameter ControlID="EnddateTextBox" DefaultValue="10/10/2012" 
                                                        Name="ToDate" PropertyName="Text" Type="DateTime" />
                                                </SelectParameters>
                                            </asp:ObjectDataSource>
                                        </td>
                                    </tr>
                                    <tr style="height: 40px;">
                                        <th style="text-align: right">
                                            Start date:&nbsp
                                        </th>
                                        <td>
                                            <asp:TextBox  ID="StartdateTextBox" CssClass="inp-datetime" runat="server" 
                                                TabIndex="1" title="(MM/dd/yyyy)"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr style="height: 10px;">
                                        <th style="text-align: right">
                                            &nbsp;</th>
                                        <td>
                                        <asp:RequiredFieldValidator ID="EnddateRequiredFieldValidator"  Display="Dynamic"
                                                runat="server" ControlToValidate="EnddateTextBox" CssClass="validation-msg" 
                                                ErrorMessage="Start date is not empty !" ForeColor="Red"></asp:RequiredFieldValidator>
                                            <asp:RegularExpressionValidator ID="EnddateRegularExpressionValidator" runat="server" 
                                                ErrorMessage="Start date is invaid !" ForeColor="Red" ControlToValidate="EnddateTextBox"  Display="Dynamic"
                                                ValidationExpression="^(((0?[1-9]|1[012])/(0?[1-9]|1\d|2[0-8])|(0?[13456789]|1[012])/(29|30)|(0?[13578]|1[02])/31)/(19|[2-9]\d)\d{2}|0?2/29/((19|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(([2468][048]|[3579][26])00)))$" 
                                                CssClass="validation-msg"></asp:RegularExpressionValidator>
                                            <asp:CompareValidator ID="DateCompareValidator" runat="server" Display="Dynamic"
                                                ControlToCompare="StartdateTextBox"
                                                ControlToValidate="EnddateTextBox" ErrorMessage="Start Date &gt; End Date" 
                                                Operator="GreaterThan" Type="Date"
                                                CssClass="validation-msg" ForeColor="Red"></asp:CompareValidator>
                                        </td>
                                    </tr>
                                    <tr valign="top" style="height: 40px;">
                                        <th style="text-align: right">
                                            End date:</th>
                                        <td>
                                            <asp:TextBox  ID="EnddateTextBox" CssClass="inp-datetime" runat="server" 
                                                TabIndex="2" title="(MM/dd/yyyy)"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr valign="top">
                                        <th>
                                            &nbsp;</th>
                                        <td>
                                            <asp:Button runat="server" ID="AddButton" CssClass="form-add" 
                                                onclick="AddButton_Click" />
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                    <div class="clear">
                    </div>
                </div>
                <!--  end content-table-inner  -->
            </td>
            <td id="tbl-border-right">
            </td>
        </tr>
        <tr>
            <td id="tbl-border-left">
                &nbsp;</td>
            <td>
                &nbsp;</td>
            <td id="tbl-border-right">
                &nbsp;</td>
        </tr>
        <tr>
            <th class="sized bottomleft">
            </th>
            <td id="tbl-border-bottom">
                &nbsp;
            </td>
            <th class="sized bottomright">
            </th>
        </tr>
    </table>
    <div class="clear">
        &nbsp;</div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="Footer" runat="server">
</asp:Content>

